package com.example.demo528.controller;

import com.example.demo528.req.DemoReq;
import com.example.demo528.resp.DemoResp;
import com.example.demo528.service.DemoService;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/demo")
public class DemoController {
    @Resource
    private DemoService demoService;

    @RequestMapping("/list")
    public List<DemoResp> list(DemoReq req){
        return demoService.list(req);
    }
}
